import request from '@/utils/request'

export function fetchtableList(data) {
  return request({
    url: '/system/metadata/table/tableList',
    method: 'post',
    data
  })
}

export function gettable(id) {
  return request({
    url: '/system/metadata/table/detail/' + id,
    method: 'get'
  })
}

export function createtable(data) {
  return request({
    url: '/system/metadata/table/add',
    method: 'post',
    data
  })
}

export function updatetable(data) {
  return request({
    url: '/system/metadata/table/update',
    method: 'post',
    data
  })
}

export function deletetable(ids) {
  return request({
    url: '/system/metadata/table/delete',
    method: 'post',
    data: { ids }
  })
}

export function exporttable(data) {
  return request({
    url: '/system/metadata/table/export',
    method: 'post',
    data
  })
}
